package com.fit.WatchShop.service;

import java.util.Collection;
import java.util.HashMap;
import java.util.Map;

import com.fit.WatchShop.interfaces.Buyer;

public class BuyersBean implements Buyers {
	
	private Map<String, Buyer> buyers = new HashMap<String, Buyer>();

    public Collection<Buyer> retrieve() {
            return buyers.values();
    }

    public Buyer save(Buyer buyer) {
            return buyers.put(buyer.getName(), buyer);
    }

    public Buyer retrieveSingleBuyer(String name) {
            return buyers.get(name);
    }


}
